package com.hyt.it.ogt.kq.service.admission;

import com.baomidou.mybatisplus.extension.service.IService;
import com.hyt.it.ogt.cj.model.entity.ProjectCollectInfo;
import com.hyt.it.ogt.cj.model.entity.ProjectCollectInfoOption;
import com.hyt.it.ogt.kq.service.model.entity.admission.ExamineeInfoExt;

import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * <p>
 * 准考证考生配置信息
 * </p>
 *
 * @author zhoumiao
 * @since 2023-01-10
 */
public interface IExamineeInfoExtService extends IService<ExamineeInfoExt> {

    /**
     * 通过id删除
     *
     * @param extIds
     */
    void deleteByIds(List<String> extIds);

    /**
     * 通过考生id和code删除
     *
     * @param deleteExtCodes
     * @param examineeId
     */
    void deleteByExamineeAndCodes(Set<String> deleteExtCodes, String examineeId);

    /**
     * 获取配置项的具体值 如果配置项有option就通过用户选择的value找到对应option中对应label值，
     * 没有option则使用户填写的value值
     *
     * @param infoValue
     * @param projectCollectInfoOptions
     * @param projectCollectInfo
     * @return
     */
    String getVariableValue(String infoValue, Map<String, List<ProjectCollectInfoOption>> projectCollectInfoOptions, ProjectCollectInfo projectCollectInfo);

    /**
     * 通过准考证考生id查询
     *
     * @param admissionId
     * @return
     */
    List<ExamineeInfoExt> listByExaminee(String admissionId);

    /**
     * 通过准考证号id和code码更新value
     *
     * @param updateExamineeInfoExt
     * @param admissionId
     * @param currentUser
     */
    void updateValueByExamineeAndCode(List<ExamineeInfoExt> updateExamineeInfoExt, String admissionId, String currentUser);
}
